import request from '@/utils/request'
// const service1 = 'http://192.168.10.165:6180'
const service1 = window.lwConfig.services.auth
const service = window.lwConfig.services.wecom + '/lxqr'

// ************************* 数据评估平台 ***************************************
// 审核侧评估项目列表
export function getApprovalList(params) {
  return request({
    url: service1 + '/sjhg/approval/assess/list',
    method: 'get',
    params,
  })
}

// 审核侧评估项目详情
export function getApprovalDetail(params) {
  return request({
    url: service1 + '/sjhg/approval/assess/detail',
    method: 'get',
    params,
  })
}

// 评估项目审核
export function approvalAssess(data) {
  return request({
    url: service1 + '/sjhg/approval/assess/approval',
    method: 'post',
    data: data,
  })
}

// 报告-草稿上传文件
export function approvalReportOneDraft(data) {
  return request({
    url: service1 + '/sjhg/approval/assess/report/one/draft',
    method: 'post',
    data: data,
  })
}

export function approvalReportDraftBind(data) {
  return request({
    url: service1 + '/sjhg/approval/assess/report/draft/bind',
    method: 'post',
    data: data,
  })
}

// 出具报告-确认
export function approvalReportOneConfirm(params) {
  return request({
    url: service1 + `/sjhg/approval/assess/report/one/confirm?assessId=${params.assessId}`,
    method: 'get',
    data: params,
  })
}

// 上传评审报告
export function approvalReportTwoConfirm(params) {
  return request({
    url: service1 + `/sjhg/approval/assess/report/two/confirm?assessId=${params.assessId}`,
    method: 'get',
    data: params,
  })
}

// 上传评审结论
export function approvalReportThreeConfirm(params) {
  return request({
    url: service1 + `/sjhg/approval/assess/report/three/confirm?assessId=${params.assessId}`,
    method: 'get',
    data: params,
  })
}

// 删除报告文件
export function delReport(params) {
  return request({
    url: service1 + `/sjhg/approval/assess/delete/report?reportId=${params.reportId}`,
    method: 'get',
    data: params,
  })
}
// 评分结果
export function approvalScore(data) {
  return request({
    url: service1 + '/sjhg/approval/assess/score',
    method: 'post',
    data: data,
  })
}

// 查看评分结果
export function getApprovalScore(params) {
  return request({
    url: service1 + '/sjhg/approval/assess/view/score',
    method: 'get',
    params,
  })
}
// 评分结果确认 1.1
export function getConfirmScore(params) {
  return request({
    url: service1 + '/sjhg/approval/assess/confirm/score',
    method: 'get',
    params,
  })
}

// 审核侧首页统计
export function getApprovalTj() {
  return request({
    url: service1 + '/sjhg/approval/assess/tj',
    method: 'get',
  })
}

// 报告列表
export function approvalReportList(params) {
  return request({
    url: service1 + `/sjhg/approval/assess/report/list?assessId=${params.assessId}&reportType=${params.reportType}`,
    method: 'get',
    data: params,
  })
}


// 确认工作计划  1.1
export function approvalCPlan(params) {
  return request({
    url: service1 + `/sjhg/approval/assess/confrimPlan`,
    method: 'get',
    params,
  })
}


// 访谈评估填报项详情 1.1
export function approvalInterviewDetail(params) {
  return request({
    url: service1 + `/sjhg/approval/assess/interview/options/detail`,
    method: 'get',
    params,
  })
}

// 提交访谈评估
export function approvalInterview(data) {
  return request({
    url: service1 + '/sjhg/approval/assess/interview',
    method: 'post',
    data: data,
  })
}
